//
// Created by Semir on 2020/5/11.
//

#include <iostream>
#include <vector>

using namespace std;

int cutRope(int number) {
    if (number <= 1) {
        return 1;
    }
    if (number < 4) {
        return number - 1;
    }
    vector<int> dp(number + 1);
    for (int i = 0; i < 4; i++) {
        dp[i] = i;
    }
    for (int i = 4; i <= number; i++) {
        dp[i] = max(dp[2] * dp[i - 2], dp[3] * dp[i - 3]);
    }
    return dp[number];
}

int main() {
    int res = cutRope(1);
    cout << res << endl;
    return 0;
}